package com.action.admin;

import java.util.List;

import com.action.BaseAction;

import org.apache.log4j.Logger;
import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Namespace;
import org.apache.struts2.convention.annotation.ParentPackage;
import org.apache.struts2.convention.annotation.Result;
import org.apache.struts2.convention.annotation.ResultPath;
/**
 * 
 * @author Administrator
 *
 */
@ParentPackage("json-default")
@Namespace("/admin")
@ResultPath("/pages")
public class ShopInfoAction extends BaseAction {

	
	private static final long serialVersionUID = 1L;
	private static Logger logger = Logger.getLogger(ShopInfoAction.class);

	/**
	 * 增加横幅图片
	 * @return
	 */
	@Action(value = "addBanner", results = {
			@Result(name = "success", location = "addBanner.jsp"),
			@Result(name = "login", location = "index.do", type = "redirect"),  })
	public String addBanner(){
		return SUCCESS;
	}
	
	/**
	 * 删除角色
	 * @return
	 */
	@Action(value = "updateBanner", results = {
			@Result(name = "success", location = "addrole.jsp"),
			@Result(name = "login", location = "index.do", type = "redirect"),  })
	public String updateBanner(){
		return SUCCESS;
	}
	
	
	/**
	 * 上传图片
	 * @return
	 */
	@Action(value = "addImage", results = {
			@Result(name = "success", location = "addrole.jsp"),
			@Result(name = "login", location = "index.do", type = "redirect"),  })
	public String addImage(){
		return SUCCESS;
	}
	
	/**
	 * 保存角色信息
	 * @return
	 */
	@Action(value = "pwdModify", results = {
			@Result(name = "success", location = "roleslist.jsp"),
			@Result(name = "login", location = "index.do", type = "redirect")  })
	public String pwdModify(){
		try {
			
		} catch (Exception e) {
			e.printStackTrace();
			logger.error(e.getMessage());
		}
		return SUCCESS;
	}
	
	private boolean flag = false;
	private List list ;
	
	public List getList() {
		return list;
	}

	public void setList(List list) {
		this.list = list;
	}

	public boolean isFlag() {
		return flag;
	}

	public void setFlag(boolean flag) {
		this.flag = flag;
	}
}
